<template>
  <div>
    <h3 style="display: inline;">操作日志</h3>
    <el-button style="margin-left: 10px;" type="warning" @click="goBack">返回</el-button>
    <el-divider ></el-divider>
    <el-table
        :data="recordData"
        :header-cell-style="{background:'#eef1f6',color:'#606266','text-align':'center',fontSize:'15px'}"
        :cell-style="{'text-align':'center'}"
        stripe
        style="width: 100%">
        <el-table-column
          prop="time"
          label="操作时间"
          sortable
          >
        </el-table-column>
        <el-table-column
          prop="gh"
          label="工号"
          >
        </el-table-column>
        <el-table-column
          prop="name"
          label="姓名"
          >
        </el-table-column>
        <el-table-column
          label="状态"
          >
          <template slot-scope="scope">
            <span v-if="scope.row.state==2">学院通过</span>
            <span v-if="scope.row.state==5">驳回 </span>
            <span v-if="scope.row.state==6">学院不通过</span>
            <span v-if="scope.row.state==-1">撤销操作</span>
            <span v-if="scope.row.state==3">专家评审</span>
          </template>
        </el-table-column>
        <el-table-column
          prop="message"
          label="备注"
          >
        </el-table-column>
      </el-table>
  </div>
</template>

<script>
   export default {
     created() {
      this.proId=this.$route.query.proId
      this.getRecordAxios()
     },
      data() {
        return {
          proId:'',
          recordData: []
        }
      },
      methods:{
        getRecordAxios(){
          this.$api.project.getRecordByProId({proId:this.proId}).then((response)=>{
            console.log(response)
            this.recordData=response.data.data
          })
        },
        goBack(){
          this.$router.go(-1)
        },
      }
    }
</script>

<style>
</style>
